package org.BUPT.infrastructure.persistent.DAO;
import org.BUPT.infrastructure.persistent.po.Question;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.repository.CrudRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface QuestionDAO extends CrudRepository<Question, Integer>  {
    Question findQuestionByIdAndIsDel(int id,int isDel);
    Page<Question> findQuestionsByIsDel(int isDel,Pageable pageable);
    List<Question> findQuestionsByUserIdAndIsDel(int userId,int isDel);
}
